
<!DOCTYPE html>
<html>

<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">


    <title>编辑博客</title>

    <link rel="shortcut icon" href="favicon.ico">
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="css/font-awesome.css" rel="stylesheet">
    <link href="css/animate.css" rel="stylesheet">
    <link href="css/plugins/iCheck/custom.css" rel="stylesheet">
    <link href="css/plugins/summernote/summernote.css" rel="stylesheet">
    <link href="css/plugins/summernote/summernote-bs3.css" rel="stylesheet">
    <link rel="stylesheet" type="text/css" href="css/plugins/webuploader/webuploader.css">
    <link rel="stylesheet" type="text/css" href="css/demo/webuploader-demo.css">
    <link href="css/style.css?v=4.1.0" rel="stylesheet">
    <link href="js/plugins/fancybox/jquery.fancybox.css" rel="stylesheet">
    <link rel="stylesheet" type="text/css" href="css/publish.css">
    <link href="css/plugins/toastr/toastr.min.css" rel="stylesheet">
</head>

<body>
<div class="col-sm-12">
    <div class="ibox float-e-margins">
        <div class="ibox-title">
            <h1>GBlog-学无止境</h1>
        </div>
        <div class="hr-line-dashed"></div>

        <form class="form-horizontal ">
            <div class="form-group">
                <label class="col-sm-1">标题</label>
                <div class="col-sm-10">
                    <input type="text" name="title" class="form-control">
                    <label class="checkbox-inline i-checks"   style="margin: 10px 20px;">
                    <input class="i-checks" type="checkbox" name="original" value="true">原创</label>
                </div>
            </div>

            <div class="hr-line-dashed"></div>

            <div class="row">
                <div class="input-group" style="width: 100%;">
                    <label class="col-sm-1">封面</label>
                    <div style="float:left;">
                        <img id="cover" src="img/p1.jpg" alt="默认封面"width="200px">
                        <div>
                            <button class="btn btn-primary" onclick="loadMaterial(1)" style="margin: 10px 11%;" data-toggle="modal" data-target="#imgs" >从素材库中选择</button>
                        </div>
                    </div>
                    <div style=" float:left;margin-left:30px;">
                        <div class="pagecontainer">
                            <div id="uploader" class="wu-example">
                                <div class="queueList">
                                    <div id="dndArea" class="placeholder">
                                        <div id="filePicker"></div>
                                        <p>更换默认封面（点击选择图片或拖拽文件到此处）</p>
                                    </div>
                                </div>
                                <div class="statusBar" style="display:none;">
                                    <div class="progress">
                                        <span class="text">0%</span>
                                        <span class="percentage"></span>
                                    </div>
                                    <div class="info"></div>
                                    <div class="btns">
                                        <div id="filePicker2"></div>
                                        <div class="uploadBtn">开始上传</div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <div class="hr-line-dashed"></div>
            <div class="row">
                <div class="col-sm-12">
                    <div class="ibox float-e-margins">
                        <div class="ibox-title">
                            <h5>博文内容</h5>
                            <button id="edit" class="btn btn-primary btn-xs m-l-sm" onclick="editArticle()" type="button">编辑</button>
                            <button id="save" class="btn btn-primary  btn-xs" onclick="saveArticle()" type="button">预览</button>
                        </div>
                        <div class="ibox-content" id="eg">

                            <div class="blogedit wrapper">

                            </div>

                        </div>
                    </div>
                </div>
            </div>

            <div class="hr-line-dashed"></div>

            <div class="form-group">
                <label class="col-sm-1">分类</label>
                <div class="col-sm-2">
                    <select id="typeList" class="form-control m-b" name="typeId">
                    </select>
                </div>
            </div>

            <div class="hr-line-dashed"></div>

            <div class="form-group">
                <label class="col-sm-1">标签</label>
                <div id="tagList" class="col-sm-10">
                </div>
            </div>

            <div class="hr-line-dashed"></div>

            <div class="hr-line-dashed"></div>
            <div class="form-group">
                <label class="col-sm-1">状态
                </label><br>
                <input class="i-checks" type="radio" value="0"  name="status">草稿
                <input class="i-checks" type="radio" value="1"  name="status">发布
            </div>

            <div class="hr-line-dashed"></div>

            <div class="form-group">
                <label class="col-sm-1">摘要</label>
                <textarea class="form-control col-md-7 col-xs-12" name="description" required="required"></textarea>
            </div>

            <div class="hr-line-dashed"></div>

            <div class="form-group">
                <label class="col-sm-1">关键词</label>
                <textarea class="form-control col-md-7 col-xs-12" name="keywords" required="required"></textarea>
            </div>

            <div class="formButtons">
                <button type="button" class="btn btn-success" id="commitArticle">保存</button>
                <button type="reset" class="btn btn-primary">重置</button>
            </div>
        </form>
    </div>
</div>
<div class="modal inmodal" id="imgs" tabindex="-1" role="dialog"  aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content animated fadeIn">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
                <div class="modal-title">素材库</div>
            </div>
            <div class="modal-body">
                <div class="row" id="material">
                    <div class="imagesDiv">
                        <input type="radio" >
                        <a class="fancybox" href="img/p1.jpg" title="图片1">
                            <img alt="image" src="img/p_big1.jpg">
                        </a>
                    </div>
                </div>
                <div class="row">
                    <ul class="pagination" style="display:block;margin:30px auto;width:300px;">
                    </ul>
                </div>
                <div class="row">
                    <div class="btn btn-primary" id="setMaterialToCover" style="display:block;margin:5px auto;width:125px;">设置选中为封面</div>
                </div>
            </div>
        </div>
    </div>
</div>

<!-- 全局js -->
<script src="js/jquery.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="js/jquery.serializejson.min.js"></script>
<!-- 自定义js -->
<script src="js/content.js"></script>
<script src="js/plugins/toastr/toastr.min.js"></script>

<!-- iCheck -->
<script src="js/plugins/iCheck/icheck.min.js"></script>
<script>
    $(document).ready(function () {
        $('.i-checks').iCheck({
            checkboxClass: 'icheckbox_square-green',
            radioClass: 'iradio_square-green',
        });
    });
</script>

<!-- SUMMERNOTE -->
<script src="js/plugins/summernote/summernote.min.js"></script>
<script src="js/plugins/summernote/summernote-zh-CN.js"></script>
<!-- Peity -->
<script src="js/plugins/peity/jquery.peity.min.js"></script>
<!-- Fancy box -->
<script src="js/plugins/fancybox/jquery.fancybox.js"></script>
<script type="text/javascript">
    // 添加全局站点信息
    var BASE_URL = 'js/plugins/webuploader';
    $(document).ready(function () {
        $('.fancybox').fancybox({
            openEffect: 'none',
            closeEffect: 'none'
        });
    });
</script>
<script src="js/plugins/webuploader/webuploader.min.js"></script>
<script src="js/publish.js" type="text/javascript"></script>
<!-- 自定义js -->
<script src="js/content.js?v=1.0.0"></script>

</body>
</html>
